package com.cs.user.infra.basic.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.cs.user.infra.basic.mapper.RoleMapper;
import com.cs.user.infra.basic.entity.Role;
import com.cs.user.infra.basic.service.RoleService;
import org.springframework.stereotype.Service;

/**
 * 角色表(Role)表服务实现类
 *
 * @author makejava
 * @since 2024-09-24 13:51:37
 */
@Service("authRoleService")
public class RoleServiceImpl extends ServiceImpl<RoleMapper, Role> implements RoleService {

    @Override
    public Boolean addRole(Role role) {
        return save(role);
    }

    @Override
    public Boolean deleteRole(Role role) {
        role.setIsDelete(1);
        return updateById(role);
    }

    @Override
    public Boolean updateRole(Role role) {
        return updateById(role);
    }
}

